{extend name="template/base" /}
{block name="content"}
<div class="page-container">
    <form class="mb-20" method="get" action="{:\\think\\Url::build($Request.action)}">
    	<input type="text" class="input-text" style="width:250px" placeholder="ID" name="id" value="{$Request.param.id}">
    	<input type="text" class="input-text" style="width:250px" placeholder="标题" name="title" value="{$Request.param.title}">
<!--    	<input type="text" class="input-text" style="width:250px" placeholder="类型ID" name="typeid" value="{$Request.param.typeid}">-->
        <button type="submit" class="btn btn-success"><i class="Hui-iconfont">&#xe665;</i> 搜索</button>
    </form>
    <div class="cl pd-5 bg-1 bk-gray">
        <span class="l">
            {tp:menu menu="add" /}
        </span>
        <span class="r pt-5 pr-5">
            共有数据 ：<strong>{$count}</strong> 条
        </span>
    </div>
    <table class="table table-border table-bordered table-hover table-bg mt-20">
        <thead>
        <tr class="text-c">
            <th width="80">ID</th>
            <th width="80">标题</th>
           	<th width="80">事件发生时间</th>
            <th width="80">内容</th>
            <!--<th width="80">类型</th>-->
            <th width="80">缩略图</th>
            <th width="80">最佳图片尺寸</th>
            <th width="80">是否裁剪过</th>
            <th width="80">裁剪图片</th>
            
            <!--<th width="80">创建时间</th>-->
            <th width="80">操作</th> 
        </tr>
        </thead>
        <tbody>
        {volist name="list" id="vo"}
        <tr class="text-c">
            <td>{$vo.id}</td>
            <td>{$vo.title}</td>
        	<td>{$vo.time}</td>
             <td>
             	{if condition="strlen($vo['content']) gt 60"}
             		<?php
             			echo    strip_tags(mb_substr($vo['content'],0,60,'utf-8')).'...';            		  
             		?>
             		{else/}            		
             		<?php
             			echo    strip_tags($vo['content']);
             		?>          	
             	{/if}
             </td>
       
            
            <td>
            	{empty  name="$vo.pic"}    
            	 	 没有图片
            	{else /} 
            		 <img src="{$vo.pic}" style="width: 50px;">           	            		
            	{/empty}
            </td>
            
            <td width="80">最佳图片尺寸</td>
            
              <td>
            	{if condition="$vo.clip  eq  0"}
            		<span  style="color: red;">未裁剪</span>
            	{else/}
            		<span style="color: blue;">已裁剪</span>
            	{/if}
            </td>
            
            <td><a href="{:url('thumb',array('id'=>$vo.id))}" class="btn btn-primary radius">裁剪</a></td>
          
            
            <td>{tp:menu menu='sedit,sdelete' url=",del:id=$vo.id"/} </td> 
         
        </tr>
        {/volist}
        </tbody>
    </table>
    <div class="page-bootstrap">{$page}</div>
</div>
{/block}